package com.group.transaction.util;

import java.util.Objects;
import java.util.UUID;

/**
 * 字符串工具类
 *
 * @author YunXing Pang
 * @date 2020/3/15
 */
public class StringUtil {

    private StringUtil () {
        super();
    }

    public static boolean isEmpty (String data) {
        return Objects.isNull(data) || data.trim().isEmpty();
    }

    public static boolean isNotEmpty (String data) {
        return !isEmpty(data);
    }

    public static String getUUID () {
        return UUID.randomUUID().toString().replaceAll("-", "");
    }

}
